﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using DevComponents.DotNetBar;

namespace XYOfficeSystem.Admin
{
    public partial class FrmMain : Office2007Form
    {
        public FrmMain()
        {
            InitializeComponent();
        }

        private void splitter1_SplitterMoved(object sender, SplitterEventArgs e)
        {

        }

        private void tsbNav_Click(object sender, EventArgs e)
        {

        }
        //private void AddNewUserTab()
        //{
        //    SuperTabItem tab = superTabControl1.CreateTab("New Tab ", 0);
        //    LabelX lbx = new LabelX();
        //    lbx.Text = "This space intentionally left blank.";
        //    lbx.TextAlignment = StringAlignment.Center;
        //    lbx.TextLineAlignment = StringAlignment.Center;
        //    lbx.BackColor = Color.Transparent;

        //    tab.AttachedControl.Controls.Add(lbx);
        //    lbx.Dock = DockStyle.Fill;

        //    UpdateDelUserButton();
        //}
        #region UpdateDelUserButton

        //private void UpdateDelUserButton()
        //{
        //    for (int i = 0; i < superTabControl1.Tabs.Count; i++)
        //    {
        //        SuperTabItem tab = superTabControl1.Tabs[i] as SuperTabItem;

        //        if (tab != null)
        //        {
        //            if (tab.Text.StartsWith("New Tab") == true)
        //            {
        //                ButtonItem bi = new ButtonItem();
        //                bi.Tag = tab;
        //                bi.Text = tab.Text;
        //            }
        //        }
        //    }
        //}

        #endregion

        private void buttonX1_Click(object sender, EventArgs e)
        {
        }

        private void treeView1_AfterSelect(object sender, TreeViewEventArgs e)
        {
        }

        private void navigationPane1_Load(object sender, EventArgs e)
        {

        }

        private void superTabControl1_SelectedTabChanged(object sender, SuperTabStripSelectedTabChangedEventArgs e)
        {

        }

        private void toolStripButton3_Click(object sender, EventArgs e)
        {
            business.FrmCredit frmCredit = new business.FrmCredit();
            frmCredit.MdiParent = this;
            frmCredit.Show();
        }

        private void tsbNavIsHide_Click(object sender, EventArgs e)
        {
            tvNav.Visible = tsbNavIsHide.Checked;
        }

        private void tsbExit_Click(object sender, EventArgs e)
        {
            if (MessageBox.Show("确认退出系统？", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Asterisk) == DialogResult.Yes)
            {
                Application.Exit();
            }
        }
    }
}
